f = 100000000


for x11 in range(0,1701):
    for x12 in range(0,1101):
        for x13 in range(0,201):
            for x14 in range(0,101):
                res = 151700-30*x11-26*x12-30*x13
                if x11+x12+x13+x14 == 2000 and f >= res:
                    f = res                         

print(res)